<h1><?php echo $this->title ?></h1>
<p><?php echo $this->description ?>

<style>
    table { border-collapse: collapse; }
    thead { border-bottom: 2px #8ab solid; border-top: 1px #8ab solid; } 
    tfoot { border-bottom: 1px solid #bde; border-top: 1px solid #bde; }
    th { color: #245; }
    .label { color: #689; }
    thead th {font-weight: normal;}
    th, td { padding: .5em .8em; } 
</style>
<table cellspacing="0">
    <thead>
        <tr>
        <?php foreach($this->plan['Schedule']['meta']['headers'] as $header) : ?>
            <th><?php echo $header[2] ?></th>
        <?php endforeach ?>
        </tr>
    </thead>
    <tbody>
        <?php foreach($this->plan['Schedule']['data'] as $row) : ?>
        <tr>
            <?php foreach($row as $col) : ?>  
                <td><?php echo $col ?></td>  
            <?php endforeach ?>
        </tr>
        <?php endforeach ?>
    </tbody>
    <tfoot>
        <tr>
        <?php foreach($this->plan['Schedule']['total'] as $total) : ?>
            <th><?php echo $total ?></th>
        <?php endforeach ?>
        </tr>
    </tfoot>
</table>

<br /><br />
<p>
    <span class="label"><?php echo $this->translate('Amount') ?>:</span> <?php echo $this->plan['Principal'] ?> -
    <span class="label"><?php echo $this->translate('Delivery date') ?>:</span> <?php echo $this->plan['DeliveryDate'] ?> - 
    <span class="label"><?php echo $this->translate('First payment date') ?>:</span> <?php echo $this->plan['FirstPaymentDate'] ?> -
    <span class="label"><?php echo $this->translate('Principal grace end date') ?>:</span> <?php echo $this->plan['PrincipalGraceEndDate'] ?> -
    <span class="label"><?php echo $this->translate('Principal grace rate') ?>:</span> <?php echo $this->plan['PrincipalGraceRate'] ?> % -
    <span class="label"><?php echo $this->translate('Principal grace interest charged') ?>:</span> <?php echo $this->plan['GracePmt'] ?> -
    <span class="label"><?php echo $this->translate('Product') ?>:</span> <?php echo $this->form['Name'] ?> -
    <span class="label"><?php echo $this->translate('Installments') ?>:</span> <?php echo $this->plan['Installments'] ?> -
    <span class="label"><?php echo $this->translate('Payment frequency') ?>:</span> <?php echo $this->plan['PaymentFrequency'] ?> -
    <span class="label"><?php echo $this->translate('Annual rate') ?>:</span> <?php echo $this->plan['AnnualPercentageRate'] ?> % -
    <span class="label"><?php echo $this->translate('Interest calculation') ?>:</span> <?php echo $this->plan['InterestCalculation'] ?> -
    <span class="label"><?php echo $this->translate('Health insurance') ?>:</span> <?php echo $this->plan['HealthInsurancePct'] ?> % -
    <span class="label"><?php echo $this->translate('Loan insurance') ?>:</span> <?php echo $this->plan['LoanInsurancePct'] ?> % -
    <span class="label"><?php echo $this->translate('Admin. fee') ?>:</span> <?php echo $this->plan['AdministrativeFeePct'] ?> %
    